/* 基础样式 */
body {
    background-color: #f8f9fa;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    color: #343a40;
    line-height: 1.6;
}

/* 头部样式 */
.layui-header {
    background: linear-gradient(135deg, #1e3c72 0%, #2a5298 100%);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 0;
}

.logo {
    display: flex;
    align-items: center;
    font-size: 22px;
    font-weight: 700;
    color: white;
}

.logo i {
    margin-right: 10px;
    font-size: 28px;
}

.nav-links {
    display: flex;
    align-items: center;
}

.nav-link {
    color: rgba(255, 255, 255, 0.8);
    margin-left: 25px;
    padding: 8px 12px;
    border-radius: 4px;
    transition: all 0.3s;
}

.nav-link:hover {
    color: white;
    background: rgba(255, 255, 255, 0.1);
    text-decoration: none;
}

.user-info {
    position: relative;
    display: flex;
    align-items: center;
    color: white;
    cursor: pointer;
    padding: 8px 12px;
    border-radius: 4px;
    transition: all 0.3s;
}

.user-info:hover {
    background: rgba(255, 255, 255, 0.1);
}

.user-info i {
    margin-right: 8px;
    font-size: 20px;
}

.dropdown-menu {
    display: none;
    position: absolute;
    top: 100%;
    right: 0;
    background: white;
    min-width: 180px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.15);
    border-radius: 4px;
    z-index: 1000;
    overflow: hidden;
}

.user-info:hover .dropdown-menu {
    display: block;
}

.dropdown-menu a {
    display: block;
    padding: 12px 20px;
    color: #495057;
    transition: all 0.3s;
}

.dropdown-menu a:hover {
    background: #f8f9fa;
    color: #1e9fff;
    text-decoration: none;
}

.dropdown-menu a i {
    margin-right: 10px;
    width: 20px;
    text-align: center;
}

/* 认证页面公共样式 */
.auth-container {
    min-height: calc(100vh - 120px);
    padding: 60px 0;
    display: flex;
    align-items: center;
}

.login-bg {
    background: linear-gradient(rgba(255, 255, 255, 0.9), rgba(255, 255, 255, 0.9)),
        url('/static/img/login.png');
    background-size: cover;
    background-position: center;
}

.register-bg {
    background: linear-gradient(rgba(255, 255, 255, 0.9), rgba(255, 255, 255, 0.9)),
        url('/static/img/register.png');
    background-size: cover;
    background-position: center;
}

.forgot-bg {
    background: linear-gradient(rgba(255, 255, 255, 0.9), rgba(255, 255, 255, 0.9)),
        url('/static/img/forget.png');
    background-size: cover;
    background-position: center;
}

.auth-card {
    background: white;
    border-radius: 12px;
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.12);
    padding: 28px;
    margin: 0 auto;
    max-width: 480px;
    width: 100%;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.1);
}


.auth-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.18);
}

.auth-header {
    text-align: center;
    margin-bottom: 26px;
    padding-bottom: 18px;
    border-bottom: 1px solid #f0f4f9;
}

.auth-header h2 {
    font-size: 26px;
    font-weight: 700;
    margin-bottom: 8px;
    color: #1e3c72;
    display: flex;
    align-items: center;
    justify-content: center;
}

.auth-header h2 i {
    margin-right: 12px;
    font-size: 28px;
}

.auth-header p {
    color: #6c757d;
    font-size: 16px;
    margin-top: 6px;
}

.auth-form {
    margin-top: 16px;
}

.inline-label {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
}

.form-group {
    margin-bottom: 20px;
}

.input-with-icon {
    position: relative;
}

.input-with-icon i {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: #6c757d;
    font-size: 18px;
    z-index: 2;
}

.input-with-icon .layui-input {
    padding-left: 48px;
    height: 48px;
    border-radius: 8px;
    border: 1px solid #e1e5eb;
    transition: all 0.3s;
    width: 100%;
    font-size: 15px;
    background: #fbfdff;
}

.input-with-icon .layui-input:focus {
    border-color: #1e9fff;
    box-shadow: 0 0 0 3px rgba(30, 159, 255, 0.15);
    background: white;
    outline: none;
}

.input-with-icon .layui-input:hover {
    border-color: #c2dbf7;
}

.input-with-icon .toggle-password {
    position: absolute;
    left: auto;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: #6c757d;
    font-size: 16px;
    cursor: pointer;
    z-index: 3;
    transition: color 0.3s ease;
}

.input-with-icon .toggle-password:hover {
    color: #1e9fff;
}

.forgot-password {
    color: #1e9fff;
    font-size: 14px;
    transition: all 0.3s;
}

.forgot-password:hover {
    color: #0d8bf2;
    text-decoration: none;
}

.agreement-group {
    margin-top: 10px;
}

.auth-btn {
    height: 50px;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    background: linear-gradient(135deg, #1e3c72 0%, #2a5298 100%);
    border: none;
    transition: all 0.3s;
    letter-spacing: 0.5px;
    margin-top: 8px;
}

.auth-btn:hover {
    opacity: 0.95;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(30, 60, 114, 0.25);
}

.auth-btn i {
    margin-right: 10px;
}


.auth-footer {
    text-align: center;
    margin-top: 24px;
    padding-top: 20px;
    border-top: 1px solid #f0f4f9;
    color: #6c757d;
    font-size: 15px;
}

.register-link,
.login-link {
    color: #1e3c72;
    font-weight: 600;
    transition: all 0.3s;
    margin-left: 5px;
}

.register-link:hover,
.login-link:hover {
    color: #1e9fff;
    text-decoration: none;
}

/* 安全提示卡片 */
.tip-card {
    background: white;
    border-radius: 10px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.05);
    overflow: hidden;
    transition: transform 0.3s, box-shadow 0.3s;
}

.tip-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
}

.tip-header {
    background: linear-gradient(135deg, #1e3c72 0%, #2a5298 100%);
    color: white;
    padding: 15px 20px;
    font-size: 18px;
    font-weight: 600;
    display: flex;
    align-items: center;
}

.tip-header i {
    margin-right: 10px;
    font-size: 20px;
}

.tip-content {
    padding: 20px;
}

.tip-content ul {
    margin: 0;
    padding: 0;
    list-style: none;
}

.tip-content li {
    padding: 10px 0;
    display: flex;
    align-items: center;
    border-bottom: 1px solid #f1f3f9;
}

.tip-content li:last-child {
    border-bottom: none;
}

.tip-content li i {
    margin-right: 12px;
    font-size: 16px;
    color: #28a745;
    min-width: 20px;
}

.text-success {
    color: #28a745 !important;
}

/* 密码强度指示器 */
#password-strength-list li {
    display: flex;
    align-items: center;
}

#password-strength-list li i {
    margin-right: 10px;
    font-size: 14px;
    color: #adb5bd;
}

/* 步骤指示器 */
.steps {
    margin-bottom: 30px;
}

.step-progress {
    display: flex;
    justify-content: space-between;
    position: relative;
    margin-bottom: 30px;
}

.step-progress::before {
    content: '';
    position: absolute;
    top: 20px;
    left: 0;
    right: 0;
    height: 4px;
    background: #e9ecef;
    z-index: 1;
}

.step {
    position: relative;
    z-index: 2;
    text-align: center;
    flex: 1;

}

.step.active .step-icon {
    background: #1e3c72;
    color: white;
    border-color: #1e3c72;
}

.step.active .step-label {
    color: #1e3c72;
    font-weight: 600;
}

.hidden {
    display: none;
}

.step-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: white;
    border: 2px solid #e9ecef;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 10px;
    font-weight: 600;
    color: #adb5bd;
    transition: all 0.3s;
}

.step-label {
    color: #6c757d;
    font-size: 14px;
    transition: all 0.3s;
}

/* 验证码样式 */

.captcha-container {
    display: flex;
    gap: 10px;
    align-items: center;
}

.captcha-input-container {
    flex: 1;
    min-width: 0;
    /* 防止flex元素溢出 */
}

.captcha-img-container {
    flex: 0 0 auto;
    position: relative;
}

.captcha-img {
    height: 46px;
    width: 120px;
    border-radius: 8px;
    cursor: pointer;
    border: 1px solid #e1e5eb;
    background: #f8fafd;
    object-fit: cover;
    transition: all 0.3s ease;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
}

.captcha-img:hover {
    border-color: #1e9fff;
    transform: translateY(-2px);
    box-shadow: 0 5px 12px rgba(30, 159, 255, 0.15);
}

.captcha-refresh {
    position: absolute;
    bottom: -22px;
    right: 0;
    font-size: 12px;
    color: #6c757d;
    white-space: nowrap;
    opacity: 0;
    transition: opacity 0.3s;
}

.captcha-img-container:hover .captcha-refresh {
    opacity: 1;
}

/* 移动设备验证码布局优化 */
@media (max-width: 576px) {
    .captcha-container {
        flex-direction: column;
    }

    .captcha-input-container {
        width: 100%;
    }

    .captcha-img-container {
        width: 100%;
        display: flex;
        justify-content: center;
    }

    .captcha-img {
        width: 150px;
        height: 44px;
    }
}

/* 页脚样式 */
.footer {
    background: #1e3c72;
    color: rgba(255, 255, 255, 0.8);
    padding-top: 40px;
}

.footer-content {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    margin-bottom: 30px;
}

.footer-section {
    flex: 1;
    min-width: 250px;
    margin-bottom: 20px;
    padding-right: 20px;
}

.footer-section h4 {
    color: white;
    margin-bottom: 20px;
    font-size: 18px;
    position: relative;
    padding-bottom: 10px;
}

.footer-section h4::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 40px;
    height: 3px;
    background: #1e9fff;
}

.footer-section p {
    margin-bottom: 15px;
}

.footer-section ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-section ul li {
    margin-bottom: 10px;
    display: flex;
    align-items: center;
}

.footer-section ul li i {
    margin-right: 10px;
    width: 20px;
}

.footer-section a {
    color: rgba(255, 255, 255, 0.8);
    transition: all 0.3s;
}

.footer-section a:hover {
    color: white;
    text-decoration: none;
    padding-left: 5px;
}

.copyright {
    text-align: center;
    padding: 20px 0;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    font-size: 14px;
    color: rgba(255, 255, 255, 0.6);
}

.security-info {
    margin-top: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.security-info i {
    margin-right: 8px;
}


/* 退出页面样式 */
.logout-container {
    padding: 50px 0;
}

.logout-box {
    background: #fff;
    border-radius: 5px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, .1);
    padding: 30px;
    margin-bottom: 20px;
    text-align: center;
}

.logout-message {
    margin: 30px 0;
    font-size: 16px;
}

.logout-message p {
    margin-bottom: 15px;
}

.logout-message .layui-icon {
    color: #5FB878;
    margin-right: 10px;
}



/* 响应式调整 */
@media (max-width: 768px) {
    .header-content {
        flex-direction: column;
        text-align: center;
    }

    .nav-links {
        margin-top: 15px;
        justify-content: center;
    }

    .nav-link {
        margin: 0 10px;
    }

    .auth-container {
        padding: 30px 0;
    }

    .auth-card {
        padding: 20px;
    }

    .input-with-icon .layui-input {
        height: 45px;
    }

    .auth-btn {
        height: 45px;
    }

    .footer-section {
        flex: 100%;
        padding-right: 0;
        margin-bottom: 30px;
    }
}